home *** CD-ROM | disk | FTP | other *** search
- {$APPTYPE CONSOLE}
- uses
- SysUtils,
- DrBobCGI, // read Keyword from CGI "Form"
- IndexBob; // read index.bob and pages.bob
- var
- Keyword: ShortString;
- Found: TPageSet;
- i: Integer;
-
- begin
- writeln('<H2>IndexBob Search Results</H2>');
- Keyword := Value('Keyword');
- writeln('Keyword: <B>',Keyword,'</B><BR>');
- if root <> nil then
- if Length(Keyword) in [3..MaxKeyword] then
- Found := Found * root.FindKeywordInPages(LowerCase(Keyword))
- else
- Found := []; // no pages found
- writeln('<BR>');
- writeln('<B>',Pages(Found),'</B> pages found:');
- writeln('<UL>');
- for i:=0 to WebPages-1 do
- if i in Found then
- writeln('<LI><A HREF="',WebPage[i],'">',WebPage[i],'</A>');
- writeln('</UL>');
- end.
-